home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_200 / 293_01 / t3.c < prev    next >
C/C++ Source or Header  |  1989-08-23  |  242b  |  12 lines

  1. #include <stdio.h>
  2. #include <math.h>
  3.  
  4. main()
  5. {
  6.   int ang;
  7.  
  8.   for (ang = 0; ang < 90; ang += 5) {
  9.     printf("ang = %d  ixmax = %d, %f\n", ang, (255*ang)/90,
  10.      127.5*(1.0 + sqrt(2.0)*sin(((double) ang - 45.0)*3.14/180.)));
  11.    }
  12. }